import { Injectable } from '@nestjs/common';
import { CreateClientLogDto } from './dto/create-client-log.dto';
import { LogRepository } from './log.repository';
import { User } from '../user/entities/user.entity';
import { Log } from './entities/log.entity';
import { CreateLogDto } from './dto/create-log.dto';
import { IPaginationOptions, Pagination } from '../utils/paginate';

@Injectable()
export class LogService extends LogRepository {
  create(createLogDto: CreateLogDto, user: User): Promise<string> {
    return super.createLog(createLogDto, user);
  }

  findAll(options: IPaginationOptions): Promise<Pagination<Log>> {
    return super.serverLog(options);
  }

  findOne(id: number) {
    return `This action returns a #${id} log`;
  }

  remove(id: number) {
    return `This action removes a #${id} log`;
  }
}
